package cn.cau.dao;

import cn.cau.entity.AuditingResult;
import cn.cau.entity.AuditingUtils;
import cn.cau.entity.CodeRule;

import java.util.List;

public interface CodeRuleDao {
    //根据id查询
    public CodeRule findCodeRuleById(int codeRuleId);
    //查询所有规则
    public List<CodeRule> findCodeRuleAll();
    //插入规则
    public int insertCodeRule(CodeRule CodeRule);
    //根据用户id查询规则
    public List<CodeRule>findCodeRuleByuserId(int userId);
    //更新规则状态
    public int updateCodeRule(CodeRule codeRule);
    //根据用户id查询可用规则
    public List<CodeRule>findLiveCodeRuleByuserId(int userId);

    public List<CodeRule>findCodeRuleByName(String name);

    public List<CodeRule>findCodeRuleByCategoryId(int categoryId);

    public int updateCodeRuleResult(AuditingResult auditingResult);

    public List<CodeRule> findCodeRuleByCategory(AuditingUtils auditingUtils);

}
